<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>SipekSDK Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
	<!-- Main table. -->
<TABLE id="MainTable" cellSpacing="0" cellPadding="0" width="100%" border="0">
<!-- First Row,  logo. -->
<TR>
 <TD>
  <TABLE cellSpacing="0" cellPadding="0" width="100%" border="0">
    <TR valign="bottom">

	<TD style="background-image: url(/images/bg1.jpg);">
	<!-- Logo section -->
	<table border="0" class="pj">
		<tr>
		<td vAlign="middle" width="46"><A href="http://sites.google.com/site/sipekvoip"><img alt="sipek logo" src="http://sites.google.com/site/sipekvoip/files/Sipek64x64.png" border="0"></A>
		</td>
		<td vAlign="top">
		<font face="Verdana,Arial,Helvetica" size="5"><b><A style="color: black; text-decoration: none" HREF="/">Sipek Software Development Kit</A></b></FONT><br>

		<FONT face="Arial,Helvetica" size="1"><A style="color: black; text-decoration: none" HREF="/">Open source SIP Software Development Kit - SipekSDK</A></FONT><br>
		<br>
<script type="text/javascript"><!--
google_ad_client = "pub-1698141058269504";
/* 728x15, created 3/21/08 */
google_ad_slot = "1887304858";
google_ad_width = 728;
google_ad_height = 15;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
		</td>
		</tr>
	</table>
	</TD>
    </TR>
  </TABLE>
 </TD>
</TR>

<!-- Second Row, a HR. -->

<TR>
    <td><hr size="2"></td>
</TR>
<!-- Third row, main contents. -->
<TR>
    <TD>
	     <TABLE id="ContentTable" cellSpacing="6" cellPadding="1" width="100%" border="0">
	     <TR valign="top">
		    <TD valign="top" width="160" style="background-image: url(/images/bg2.jpg);">

<h3>Links </h3>

<p><a href="http://sites.google.com/site/sipekvoip">Sipek Projects Home</a></p>

<p><a href="http://sites.google.com/site/sipekvoip/sipeksdk">SipekSdk</a></p>

<p><a href="http://sites.google.com/site/sipekvoip/Home/documentation/tutorial">SipekSdk Tutorial</a></p>

<p><a href="http://code.google.com/p/sipek2/">Sipek Softphone Project Home</a></p>

<p><a href="http://code.google.com/p/sipeksdk/">SipekSDK Project Home</a></p>

<p><a href="http://groups.google.com/group/sipek">Sipek Discussion Group</a></p>
<hr size="2">
<b>About:</b><FONT face="Arial, Verdana" size="1"> Sipek and SipekSDK are created by: Sasa Coh<br>
<br>

<script type="text/javascript"><!--
google_ad_client = "pub-1698141058269504";
/* 160x600, created 3/21/08 */
google_ad_slot = "1219054775";
google_ad_width = 160;
google_ad_height = 600;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
<p></p>

		    </TD>
		    <TD vAlign="top" style="border-left: dotted 1px; border-color=#C0C0C0;">&nbsp;</td>
      <TD>

	<p><A HREF="/">Home</A> --&gt; SipekSDK API Reference</p>
<!-- Generated by Doxygen 1.5.5 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="namespaces.html"><span>Packages</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="annotated.html"><span>Class&nbsp;List</span></a></li>
      <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&nbsp;Members</span></a></li>
    </ul>
  </div>
  <div class="navpath"><b>Sipek</b>.<b>Common</b>.<a class="el" href="class_sipek_1_1_common_1_1_i_presence_and_messaging.html">IPresenceAndMessaging</a>
  </div>
</div>
<div class="contents">
<h1>Sipek.Common.IPresenceAndMessaging Class Reference</h1><!-- doxytag: class="Sipek::Common::IPresenceAndMessaging" -->Abstract class for presence and instant messaging handling.  
<a href="#_details">More...</a>
<p>
Inherited by Sipek.Sip.pjsipPresenceAndMessaging.
<p>

<p>
<a href="class_sipek_1_1_common_1_1_i_presence_and_messaging-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">abstract int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_sipek_1_1_common_1_1_i_presence_and_messaging.html#d54a867b548b83410c84144862855bd5">addBuddy</a> (string ident, bool presence, int accId)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Add buddy to buddy list and subscribe presence.  <a href="#d54a867b548b83410c84144862855bd5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_sipek_1_1_common_1_1_i_presence_and_messaging.html#52a952bda699156ab7d8500c016428cc">addBuddy</a> (string ident, bool presence)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Add buddy to buddy list and subscribe presence.  <a href="#52a952bda699156ab7d8500c016428cc"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">abstract int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_sipek_1_1_common_1_1_i_presence_and_messaging.html#fe3a16a488e0080a0730d66cf6936779">delBuddy</a> (int buddyId)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Delete buddy with given identification.  <a href="#fe3a16a488e0080a0730d66cf6936779"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">abstract int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_sipek_1_1_common_1_1_i_presence_and_messaging.html#575642a7ab5f6189e89e09317fc45157">sendMessage</a> (string destAddress, string message)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Send Instant Message.  <a href="#575642a7ab5f6189e89e09317fc45157"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">abstract int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_sipek_1_1_common_1_1_i_presence_and_messaging.html#8a863f9293e7d7085de2dcff0f246e06">sendMessage</a> (string destAddress, string message, int accId)</td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">abstract int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_sipek_1_1_common_1_1_i_presence_and_messaging.html#fec55881326487dc7a0b505eb18bda4a">setStatus</a> (int accId, EUserStatus presence_state)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set device status for default account.  <a href="#fec55881326487dc7a0b505eb18bda4a"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Protected Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_sipek_1_1_common_1_1_i_presence_and_messaging.html#a7cca830c78fcecc3d828602c83726e1">BaseMessageReceived</a> (string from, string text)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">MessageReceived event trigger by VoIP stack when instant message arrived.  <a href="#a7cca830c78fcecc3d828602c83726e1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_sipek_1_1_common_1_1_i_presence_and_messaging.html#c60fbb1cd83f32f2630e375022e12e97">BaseBuddyStatusChanged</a> (int buddyId, int status, string text)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">BuddyStatusChanged event trigger by VoIP stack when buddy status changed.  <a href="#c60fbb1cd83f32f2630e375022e12e97"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Events</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DBuddyStatusChanged&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_sipek_1_1_common_1_1_i_presence_and_messaging.html#2f80b4319a414ffa787a64c5e42f9197">BuddyStatusChanged</a></td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Buddy status changed notifier.  <a href="#2f80b4319a414ffa787a64c5e42f9197"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DMessageReceived&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_sipek_1_1_common_1_1_i_presence_and_messaging.html#f2fb6d664e95e45f70140ed1fc4bd4d7">MessageReceived</a></td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Message received notifier.  <a href="#f2fb6d664e95e45f70140ed1fc4bd4d7"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Abstract class for presence and instant messaging handling. 
<p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="d54a867b548b83410c84144862855bd5"></a><!-- doxytag: member="Sipek::Common::IPresenceAndMessaging::addBuddy" ref="d54a867b548b83410c84144862855bd5" args="(string ident, bool presence, int accId)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">abstract int Sipek.Common.IPresenceAndMessaging.addBuddy           </td>
          <td>(</td>
          <td class="paramtype">string&nbsp;</td>
          <td class="paramname"> <em>ident</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&nbsp;</td>
          <td class="paramname"> <em>presence</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>accId</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Add buddy to buddy list and subscribe presence. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>ident</em>&nbsp;</td><td>buddy identification</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd></dd></dl>

</div>
</div><p>
<a class="anchor" name="52a952bda699156ab7d8500c016428cc"></a><!-- doxytag: member="Sipek::Common::IPresenceAndMessaging::addBuddy" ref="52a952bda699156ab7d8500c016428cc" args="(string ident, bool presence)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int Sipek.Common.IPresenceAndMessaging.addBuddy           </td>
          <td>(</td>
          <td class="paramtype">string&nbsp;</td>
          <td class="paramname"> <em>ident</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&nbsp;</td>
          <td class="paramname"> <em>presence</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Add buddy to buddy list and subscribe presence. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>ident</em>&nbsp;</td><td>Buddy identification</td></tr>
    <tr><td valign="top"></td><td valign="top"><em>presence</em>&nbsp;</td><td>Flag if buddy is to subscribe sip presence</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd></dd></dl>

</div>
</div><p>
<a class="anchor" name="fe3a16a488e0080a0730d66cf6936779"></a><!-- doxytag: member="Sipek::Common::IPresenceAndMessaging::delBuddy" ref="fe3a16a488e0080a0730d66cf6936779" args="(int buddyId)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">abstract int Sipek.Common.IPresenceAndMessaging.delBuddy           </td>
          <td>(</td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>buddyId</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Delete buddy with given identification. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>buddyId</em>&nbsp;</td><td>buddy identification</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd></dd></dl>

</div>
</div><p>
<a class="anchor" name="575642a7ab5f6189e89e09317fc45157"></a><!-- doxytag: member="Sipek::Common::IPresenceAndMessaging::sendMessage" ref="575642a7ab5f6189e89e09317fc45157" args="(string destAddress, string message)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">abstract int Sipek.Common.IPresenceAndMessaging.sendMessage           </td>
          <td>(</td>
          <td class="paramtype">string&nbsp;</td>
          <td class="paramname"> <em>destAddress</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">string&nbsp;</td>
          <td class="paramname"> <em>message</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Send Instant Message. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>destAddress</em>&nbsp;</td><td>Destination part of URI</td></tr>
    <tr><td valign="top"></td><td valign="top"><em>message</em>&nbsp;</td><td>Message Content</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd></dd></dl>

</div>
</div><p>
<a class="anchor" name="8a863f9293e7d7085de2dcff0f246e06"></a><!-- doxytag: member="Sipek::Common::IPresenceAndMessaging::sendMessage" ref="8a863f9293e7d7085de2dcff0f246e06" args="(string destAddress, string message, int accId)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">abstract int Sipek.Common.IPresenceAndMessaging.sendMessage           </td>
          <td>(</td>
          <td class="paramtype">string&nbsp;</td>
          <td class="paramname"> <em>destAddress</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">string&nbsp;</td>
          <td class="paramname"> <em>message</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>accId</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>destAddress</em>&nbsp;</td><td></td></tr>
    <tr><td valign="top"></td><td valign="top"><em>message</em>&nbsp;</td><td></td></tr>
    <tr><td valign="top"></td><td valign="top"><em>accId</em>&nbsp;</td><td></td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd></dd></dl>

</div>
</div><p>
<a class="anchor" name="fec55881326487dc7a0b505eb18bda4a"></a><!-- doxytag: member="Sipek::Common::IPresenceAndMessaging::setStatus" ref="fec55881326487dc7a0b505eb18bda4a" args="(int accId, EUserStatus presence_state)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">abstract int Sipek.Common.IPresenceAndMessaging.setStatus           </td>
          <td>(</td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>accId</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">EUserStatus&nbsp;</td>
          <td class="paramname"> <em>presence_state</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Set device status for default account. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>accId</em>&nbsp;</td><td>Account id</td></tr>
    <tr><td valign="top"></td><td valign="top"><em>presence_state</em>&nbsp;</td><td>Presence state - User Status</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd></dd></dl>

</div>
</div><p>
<a class="anchor" name="a7cca830c78fcecc3d828602c83726e1"></a><!-- doxytag: member="Sipek::Common::IPresenceAndMessaging::BaseMessageReceived" ref="a7cca830c78fcecc3d828602c83726e1" args="(string from, string text)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Sipek.Common.IPresenceAndMessaging.BaseMessageReceived           </td>
          <td>(</td>
          <td class="paramtype">string&nbsp;</td>
          <td class="paramname"> <em>from</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">string&nbsp;</td>
          <td class="paramname"> <em>text</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [protected]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
MessageReceived event trigger by VoIP stack when instant message arrived. 
<p>

</div>
</div><p>
<a class="anchor" name="c60fbb1cd83f32f2630e375022e12e97"></a><!-- doxytag: member="Sipek::Common::IPresenceAndMessaging::BaseBuddyStatusChanged" ref="c60fbb1cd83f32f2630e375022e12e97" args="(int buddyId, int status, string text)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Sipek.Common.IPresenceAndMessaging.BaseBuddyStatusChanged           </td>
          <td>(</td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>buddyId</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>status</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">string&nbsp;</td>
          <td class="paramname"> <em>text</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [protected]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
BuddyStatusChanged event trigger by VoIP stack when buddy status changed. 
<p>

</div>
</div><p>
<hr><h2>Event Documentation</h2>
<a class="anchor" name="2f80b4319a414ffa787a64c5e42f9197"></a><!-- doxytag: member="Sipek::Common::IPresenceAndMessaging::BuddyStatusChanged" ref="2f80b4319a414ffa787a64c5e42f9197" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">DBuddyStatusChanged Sipek.Common.IPresenceAndMessaging.BuddyStatusChanged          </td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Buddy status changed notifier. 
<p>

</div>
</div><p>
<a class="anchor" name="f2fb6d664e95e45f70140ed1fc4bd4d7"></a><!-- doxytag: member="Sipek::Common::IPresenceAndMessaging::MessageReceived" ref="f2fb6d664e95e45f70140ed1fc4bd4d7" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">DMessageReceived Sipek.Common.IPresenceAndMessaging.MessageReceived          </td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Message received notifier. 
<p>

</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li>IPresenceAndMessaging.cs</ul>
</div>
<hr><center>
<font face="Arial,Helvetica" size="1">SipekSdk - Open Source VoIP Software Development Kit<br>
<i>(c)2007-2008 Sasa Coh </i><a href="mailto:sasacoh@gmail.com">sasacoh@gmail.com</a></font>
</center>

				</TD>
				<TD vAlign="top"></TD>

			    </TR>
			</TABLE>
		    </TD>
		</TR>
	    </TABLE>
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
var pageTracker = _gat._getTracker("UA-2163858-11");
pageTracker._trackPageview();
</script>

</BODY>
</HTML>
